#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# ----------------------------------------------------------
# -- This's demo tset
# --
# ****************************
# Author: lmay.Zhou
# Blog: www.lmaye.com
# Date: 2017年8月2日 18:07:11
# ----------------------------------------------------------

import os
import sys
from PyQt5.QtWidgets import QApplication
from pip._vendor import requests
from files.socket.SocketClient import SocketClient
from files.tools import FileBaseInfo


class Test(object):
    def __init__(self):
        pass;

    def socketClient(self):
        sc = SocketClient();
        sendMsg = "Y00000001";
        sc.sendMsg(sendMsg);
        return sc.receiveMsg();

        # download = Download(1, "test.txt");
        # download.to_string();
        #
        # upload = Upload(1, "test.txt");
        # upload.to_string();

        # fileBaseInfo = FileBaseInfo();
        # fileBaseInfo.getFileBaseInfo(r"F:\test\1.jpg");
        # print("fileSize : %s\nfileDate: %s\nfileMd5: %s" % (fileBaseInfo.fileSize, fileBaseInfo.fileDate, fileBaseInfo.fileMd5));
        # print("***************************************")
        # fileBaseInfo2 = FileBaseInfo();
        # fileBaseInfo2.getFileBaseInfo(r"F:\test\11.jpg");
        # print("fileSize : %s\nfileDate: %s\nfileMd5: %s" % (fileBaseInfo2.fileSize, fileBaseInfo2.fileDate, fileBaseInfo2.fileMd5));
        # print("fileBaseInfo.fileMd5 == fileBaseInfo2.fileMd5 : (%s)" % (fileBaseInfo.fileMd5 == fileBaseInfo2.fileMd5));

        # url = "http://odwri47wq.bkt.clouddn.com/32707158_35.jpg";
        # fileName = url.split('/')[-1];
        # print(fileName)
        # rs = requests.get(url);
        # print(rs.content);

        # print("获取当前目录", os.getcwd());
        # print("获取当前目录", os.path.abspath("."));
        # print("获取上级目录", os.path.abspath("../.."));
